﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="RoleInDepartment.aspx.cs" Inherits="HRProject.Department.RoleInDepartment" MasterPageFile="~/Front2.Master" %>
<asp:Content ID="IncludePlaceHolder" ContentPlaceHolderID="IncludePlaceHolder" runat="server">
    <script type="text/javascript" language="javascript" src="/js/tree.js"></script>
    <script type="text/javascript" language="javascript" src="/js/role.js"></script>
</asp:Content>
<asp:Content ID="TitleIconPlaceHolder" ContentPlaceHolderID="TitleIconPlaceHolder" runat="server">
    <img src="/image/layout/icon/RoleIcon.png" alt="" />
</asp:Content>
<asp:Content ID="TitleNamePlaceHolder" ContentPlaceHolderID="TitleNamePlaceHolder" runat="server">
    Role in department
</asp:Content>
<asp:Content ID="LeftPanelPlaceHolder" ContentPlaceHolderID="LeftPanelPlaceHolder" runat="server">
    <div>
        <div class="tree">
        <%
            printDepartmentNode(Company);
        %>
        </div>
    </div>
</asp:Content>
<asp:Content ID="RightPanelPlaceHolder" ContentPlaceHolderID="RightPanelPlaceHolder" runat="server">
    <div>
        Roles in Department:<br />
        <div style="float:left;min-width:200px;min-height:100px">
            <%
                for (int i = 0; i < DepartmentRoles.Count; i++)
                {
                    if (!Guid.Empty.Equals(DepartmentRoles[i].Department.Id))
                    {
                        %>
                        <div class="line" onmousemove="treeNodeMove(this)" onmouseout="treeNodeOut(this)">
                            <div class="node"><%= DepartmentRoles[i].Name %></div>
                            <div class="actionbar">
                                <div class="item remove" onclick="removeRoleFromDepartment(this)"></div>
                                <input type="hidden" name="hdfRoleId" value="<%= DepartmentRoles[i].Id %>"/>
                            </div>
                        </div>
                        <%
                    }
                }
            %>
            <br />
        </div>
    </div>
</asp:Content>